"use strict";
/**
 * @author zhaojiuyi
 * @date 2022/5/24-22:54
 * @version 1.0.0
 */
import * as echarts from 'echarts'
let name = ["歌曲数量", "歌单热度"];
let option = {
  tooltip: {
    trigger: 'item',
    axisPointer: { // 坐标轴指示器，坐标轴触发有效
      type: 'line' // 默认为直线，可选为：'line' | 'shadow'
    },
    textStyle: {
      fontSize: 16
    }
  },
  "legend": {
    "left": "42%",
    "top": "5%",
    "show": true,
    "type": "scroll",
    "data": name,
    "itemWidth": 20,
    "itemHeight": 15,
    "itemGap": 30,
    "textStyle": {
      "fontSize": 14,
      "color": "#fff",
      "fontFamily": "Microsoft YaHei"
    },
  },
  "grid": [
    {
      "left": "20px",
      "right": "55%",
      "top": 50,
      "bottom": "10"
    }, {
      "left": "55%",
      "right": "20px",
      "top": 50,
      "bottom": "10"
    }],
  "xAxis": [
    {
      "type": "value",
      "gridIndex": 0,
      "inverse": true,
      "axisLine": {
        "show": false,
      },
      "splitLine": {
        "show": false,
      },
      "axisTick": {
        "show": false,
      },
      "axisLabel": {
        "show": false,
      },
      "data": [],
    },
    {
      "type": "value",
      "gridIndex": 1,
      "inverse": false,
      "axisLine": {
        "show": false,
      },
      "splitLine": {
        "show": false,
      },
      "axisTick": {
        "show": false,
      },
      "axisLabel": {
        "show": false,
      },
      "data": [],
    }],
  "yAxis": [
    {
      "type": "category",
      offset: 0,
      "axisLine": {
        "show": false,
      },
      "splitLine": {
        "show": false,
      },
      "axisTick": {
        "show": false,
      },
      "axisLabel": {
        "show": true,
        "fontSize": 14,
        "color": "rgba(198,206,201,0.7)",
      },
      "data": ['歌单1', '歌单2', '歌单3', '歌单4', '歌单5', '歌单6'],
      position: 'right',
    },
    {
      "type": "category",
      "gridIndex": 1,
      "axisLine": {
        "show": false,
      },
      "splitLine": {
        "show": false,
      },
      "axisTick": {
        "show": false,
      },
      "axisLabel": {
        "show": true,
        "fontSize": 14,
        "color": "rgba(265,242,53,0.7)",
      },
      "data": ['', '', '', '', '', ''],

    }],
  "series": [
    {
      "colId": "col402utokg",
      "name": name[0],
      "type": "bar",
      "data": [123 ,208,350, 456,506,566],
      barWidth: 15,
      color: '#00f3df',
      "xAxisIndex": 0,
      "yAxisIndex": 0,
      itemStyle: {
        normal: {
          barBorderRadius: [10, 10, 10, 10],
          color: new echarts.graphic.LinearGradient(0, 0, 1, 0, [{
            offset: 0,
            color: 'rgba(65,250,240,1)'
          },
            {
              offset: 1,
              color: "rgba(43,163,205,0)"
            }
          ])
        }
      },
      "label": {
        "position": "left",
        "fontFamily": "Microsoft YaHei",
        "show": true,
        "fontSize": 14,
        "color": "#fff"
      }
    },
    {
      "colId": "col3kkgr6h9",
      "name": name[1],
      "type": "bar",
      "data": [323, 408, 450, 456, 556,633],
      barWidth:15,
      color: '#01b3e0',
      "xAxisIndex": 1,
      "yAxisIndex": 1,
      itemStyle: {
        normal: {
          barBorderRadius: [10, 10, 10, 10],
          color: new echarts.graphic.LinearGradient(1, 0, 0, 0, [{
            offset: 0,
            color: "rgba(265,242,53,1)"
          },
            {
              offset: 1,
              color: "rgba(265,242,53,0)"
            }
          ])
        }
      },
      "label": {
        "position": "right",
        "fontFamily": "Microsoft YaHei",
        "show": true,
        "fontSize": 14,
        "color": "#fff",
      }
    }],
}

export {option}
